.class Lcom/openfeint/internal/OpenFeintInternal$2;
.super Lcom/openfeint/internal/request/RawRequest;
.source "OpenFeintInternal.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lcom/openfeint/internal/OpenFeintInternal;->createDeviceSession()V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$0:Lcom/openfeint/internal/OpenFeintInternal;


# direct methods
.method constructor <init>(Lcom/openfeint/internal/OpenFeintInternal;Lcom/openfeint/internal/request/OrderedArgList;)V
    .locals 0
    .parameter
    .parameter "$anonymous0"

    .prologue
    .line 1
    iput-object p1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    .line 361
    invoke-direct {p0, p2}, Lcom/openfeint/internal/request/RawRequest;-><init>(Lcom/openfeint/internal/request/OrderedArgList;)V

    return-void
.end method


# virtual methods
.method public method()Ljava/lang/String;
    .locals 1

    .prologue
    .line 362
    const-string v0, "POST"

    return-object v0
.end method

.method public needsDeviceSession()Z
    .locals 1

    .prologue
    .line 364
    const/4 v0, 0x0

    return v0
.end method

.method public onResponse(ILjava/lang/Object;)V
    .locals 4
    .parameter "responseCode"
    .parameter "responseBody"

    .prologue
    const/4 v3, 0x0

    .line 366
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    const/4 v2, 0x0

    #setter for: Lcom/openfeint/internal/OpenFeintInternal;->mCreatingDeviceSession:Z
    invoke-static {v1, v2}, Lcom/openfeint/internal/OpenFeintInternal;->access$1(Lcom/openfeint/internal/OpenFeintInternal;Z)V

    .line 368
    const/16 v1, 0xc8

    if-gt v1, p1, :cond_2

    const/16 v1, 0x12c

    if-ge p1, v1, :cond_2

    .line 369
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    const/4 v2, 0x1

    #setter for: Lcom/openfeint/internal/OpenFeintInternal;->mDeviceSessionCreated:Z
    invoke-static {v1, v2}, Lcom/openfeint/internal/OpenFeintInternal;->access$2(Lcom/openfeint/internal/OpenFeintInternal;Z)V

    .line 370
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #getter for: Lcom/openfeint/internal/OpenFeintInternal;->mPostDeviceSessionRunnable:Ljava/lang/Runnable;
    invoke-static {v1}, Lcom/openfeint/internal/OpenFeintInternal;->access$3(Lcom/openfeint/internal/OpenFeintInternal;)Ljava/lang/Runnable;

    move-result-object v1

    if-eqz v1, :cond_0

    .line 371
    sget-object v1, Lcom/openfeint/internal/OpenFeintInternal$2;->TAG:Ljava/lang/String;

    const-string v2, "Launching post-device-session runnable now."

    invoke-static {v1, v2}, Lcom/openfeint/internal/OpenFeintInternal;->log(Ljava/lang/String;Ljava/lang/String;)V

    .line 372
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    iget-object v1, v1, Lcom/openfeint/internal/OpenFeintInternal;->mMainThreadHandler:Landroid/os/Handler;

    iget-object v2, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #getter for: Lcom/openfeint/internal/OpenFeintInternal;->mPostDeviceSessionRunnable:Ljava/lang/Runnable;
    invoke-static {v2}, Lcom/openfeint/internal/OpenFeintInternal;->access$3(Lcom/openfeint/internal/OpenFeintInternal;)Ljava/lang/Runnable;

    move-result-object v2

    invoke-virtual {v1, v2}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    .line 381
    :cond_0
    :goto_0
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #getter for: Lcom/openfeint/internal/OpenFeintInternal;->mQueuedPostDeviceSessionRunnables:Ljava/util/List;
    invoke-static {v1}, Lcom/openfeint/internal/OpenFeintInternal;->access$6(Lcom/openfeint/internal/OpenFeintInternal;)Ljava/util/List;

    move-result-object v1

    if-eqz v1, :cond_1

    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #getter for: Lcom/openfeint/internal/OpenFeintInternal;->mQueuedPostDeviceSessionRunnables:Ljava/util/List;
    invoke-static {v1}, Lcom/openfeint/internal/OpenFeintInternal;->access$6(Lcom/openfeint/internal/OpenFeintInternal;)Ljava/util/List;

    move-result-object v1

    invoke-interface {v1}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v1

    :goto_1
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v2

    if-nez v2, :cond_3

    .line 385
    :cond_1
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #setter for: Lcom/openfeint/internal/OpenFeintInternal;->mPostDeviceSessionRunnable:Ljava/lang/Runnable;
    invoke-static {v1, v3}, Lcom/openfeint/internal/OpenFeintInternal;->access$7(Lcom/openfeint/internal/OpenFeintInternal;Ljava/lang/Runnable;)V

    .line 386
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #setter for: Lcom/openfeint/internal/OpenFeintInternal;->mQueuedPostDeviceSessionRunnables:Ljava/util/List;
    invoke-static {v1, v3}, Lcom/openfeint/internal/OpenFeintInternal;->access$8(Lcom/openfeint/internal/OpenFeintInternal;Ljava/util/List;)V

    .line 387
    return-void

    .line 376
    :cond_2
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #setter for: Lcom/openfeint/internal/OpenFeintInternal;->mPostLoginRunnable:Ljava/lang/Runnable;
    invoke-static {v1, v3}, Lcom/openfeint/internal/OpenFeintInternal;->access$4(Lcom/openfeint/internal/OpenFeintInternal;Ljava/lang/Runnable;)V

    .line 377
    iget-object v1, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    #calls: Lcom/openfeint/internal/OpenFeintInternal;->showOfflineNotification(ILjava/lang/Object;)V
    invoke-static {v1, p1, p2}, Lcom/openfeint/internal/OpenFeintInternal;->access$5(Lcom/openfeint/internal/OpenFeintInternal;ILjava/lang/Object;)V

    goto :goto_0

    .line 381
    :cond_3
    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v0

    check-cast v0, Ljava/lang/Runnable;

    .line 382
    .local v0, r:Ljava/lang/Runnable;
    iget-object v2, p0, Lcom/openfeint/internal/OpenFeintInternal$2;->this$0:Lcom/openfeint/internal/OpenFeintInternal;

    iget-object v2, v2, Lcom/openfeint/internal/OpenFeintInternal;->mMainThreadHandler:Landroid/os/Handler;

    invoke-virtual {v2, v0}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    goto :goto_1
.end method

.method public path()Ljava/lang/String;
    .locals 1

    .prologue
    .line 363
    const-string v0, "/xp/devices"

    return-object v0
.end method
